package com.atguigu.common.vo;

import com.atguigu.common.to.elastic.SkuElasticModel;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * @Author LiDeJie
 * @Create 2024/1/24 20:11
 * @Version 1.0
 */
@Data
public class SearchResp {
    
    private List<SkuElasticModel> products;
    
    /**
     * 分类Vo
     */
    private List<catalogVo> catalogVos;
    
    /**
     * 品牌Vo
     */
    private List<BrandVo> brandVos;
    
    /**
     * 当前页
     */
    private Integer pageNum;
    
    /**
     * 总记录数
     */
    private Long total;
    
    /**
     * 总页码
     */
    private Integer totalPages;
    
    /**
     * 分页导航页
     */
    private List<Integer> pageNavs;
    
    /**
     * 面包屑功能
     */
    private List<NavVo> navs = new ArrayList<>();
    
    /**
     * 属性面包屑Ids
     */
    private List<Long> attrIds = new ArrayList<>();
    
    @Data
    public static class NavVo {
        /**
         * 属性名称
         */
        private String navName;
        
        /**
         * 属性值
         */
        private String navValue;
        
        /**
         * 要跳转的地址
         */
        private String link;
    }
    
    /**
     * 属性
     */
    private List<Attrs> attrs;
    
    @Data
    public static class Attrs {
        private Long attrId;
        
        private String attrName;
        
        private List<String> attrValue;
    }
    
    @Data
    public static class BrandVo {
        
        private Long brandId;
        
        private String brandName;
        
        private String brandImg;
    }
    
    @Data
    public static class catalogVo {
        
        private Long catalogId;
        
        private String catalogName;
    }
    
}
